package data.vip;

import java.io.Serializable;
import data.goods.Goods;
import data.goods.StockList;

@SuppressWarnings("serial")
public class SendRecord implements Serializable{
     private String ID;
     private String vipID;
     private String goodsID;
     private int num;
     private String date;
     private Vip vip;
     private Goods goods=new Goods();
     
     public SendRecord(String ID,String vipID,String goodsID,int num,String date){
    	 this.ID=ID;
    	 this.vipID=vipID;
    	 this.goodsID=goodsID;
    	 this.num=num;
    	 this.date=date;
    	 setVip();
    	 setGoods();
     }
     
     private void setVip(){
    	 VipList viplist=new VipList();
    	 vip=(Vip) viplist.idFind(vipID);
     }
     

     private void setGoods(){
    	StockList stock=new StockList();
    	 goods=(Goods) stock.idFind(goodsID);
     }
     
     public String getID(){
    	 return ID;
     }
     
     
     public String getVipID(){
    	 return vip.getID();
     }
     
     public String getVipName(){
    	 return vip.getName();
     }
     
     public String getGiftName(){
    	 return goods.getName();
     }
     public String getGiftID(){
    	 return goods.getID();
     }
     
     public int getGiftNum(){
    	 return num;
     }
     
     public String getDate(){
    	 return date;
     }
}
